﻿using System;
using System.Collections.Generic;
using System.Threading.Tasks;
using XConductor.Domain.Seedwork.Capturing.Settings;

namespace XConductor.Domain.Seedwork.Capturing
{
    public interface ICaptureSession : IDisposable
    {
        event EventHandler<CaptureEventArgs> OnSoundLeveChanged;

        event EventHandler<CaptureEventArgs> OnStart;
        event EventHandler<CaptureEventArgs> OnStop;

        event EventHandler<CaptureEventArgs> OnInterrupted;

        event EventHandler<CaptureRuntimeExceptionEventArgs> RuntimeError;

        ICaptureSettings Settings { get; }

        bool Interrupted { get; }
        bool Running { get; }

        Task Start();
        Task Stop();

        Task Initialize(ICaptureSettings settings);
    }
}
